1. Field of the Invention
This invention relates to information systems. In particular, the invention relates to multimedia information streaming in a multi-process environment.
2. Description of Related Art
A typical multimedia application such as video conferencing involves a large amount of information including video, audio, and data, that need to be processed in a timely manner. With the proliferation of personal computer (PC) hardware and software technologies, more and more multimedia applications are implemented on the PC platform supported by multi-process operating systems. A multi-process operating system (OS) supports concurrent and asynchronous processes. Modern operating systems allow concurrent execution of multiple processes on multiple CPU""s, substantially increasing system performance.
In dealing with multiple processes, the OS has to maintain the integrity of each process. Robustness and security are two most important issues in multi-process OS. However, in providing robustness and security, the OS may have to compromise the performance in terms of efficient utilization of resources (e.g., memory) and processing time. One important problem in dealing with concurrent and asynchronous processes is the interprocess communication (IPC). One common type of IPC is the producer-consumer relationship. In this relationship, one process, a producer, generates information to be used or received by one or more other processes, a consumer process.
In a multi-process operating system, a process defines a virtual address space within which an application""s code and data reside. The operating system (OS) maintains a private address space for each application that is unique and protected from other applications. Although this architecture is useful for security purposes, it makes it difficult to share data between address spaces. In a typical producer-consumer relationship, this limitation implies that the producer has to have the operating system replicate the information before sending to each consumer. For multimedia applications, the replication of information is undesirable because of the amount of data involved.
In multimedia applications, the process boundaries between the producer and consumer are particularly relevant. For example, a video conference typically involves the transfer of information from one computer to several other computers via a network. It is not uncommon for a producer to generate several video frames per second, at several hundred kilobytes per frame. These video frames are typically processed by multiple consumers. One consumer displays the captured video to the screen while another consumer compresses the video frames and transmits them to the other computers in the video conference over the network. If the video conference was being recorded for future reference, a third consumer of these video frames might be responsible for saving a copy of the video frames to a disk drive or other non-volatile storage medium.
Accordingly, there is a need in the technology to provide an efficient information streaming of multimedia information in a multi-process software environment.
The present invention discloses a method and system for streaming an information stream from a producer to N consumers in a multi-process environment. An inter-process communication (IPC) channel containing a shared memory is provided between the producer and at least one of N consumers. The information stream is written into the shared memory by way of a producer-side interface. The information stream is read from the shared memory by way of a consumer-side interface.